﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using System.Threading;

namespace AI3SaveEditor
{
    public partial class ProgressForm : Form
    {
        private ProgressForm() {
            InitializeComponent();
        }

        public ProgressForm(int max, string message, string title)
            : this() {
            this.progressBar.Value = 1;
            this.progressBar.Maximum = max;
            this.message.Text = message;
            this.title.Text = title;
            this.Show();
        }

        public void UpdateMessage(string message) {
            UpdateMessage(message, 1);
        }

        public void UpdateMessage(string message, int value) {
            progressBar.PerformStep();
            this.message.Text = message;
            this.Update();
        }

        private void ProgressForm_FormClosing(object sender, FormClosingEventArgs e) {

        }
    }
}
